/* cellInfo
	@author 李飞飞
 */
class CellInfo {
	constructor(info) {
		this.info = info;
	}

	element() {
		let cellInfo = document.createElement("div");
		cellInfo.className = "cell-info";
		// let h4 = document.createElement("strong");
		// h4.innerHTML = "编号：" + this.info.id;
		// let p = document.createElement("span");
		// p.innerHTML = "名称：" + this.info.innerText;
		// cellInfo.appendChild(h4);
		// cellInfo.appendChild(p);

		cellInfo.innerHTML = "<strong>编号：" + this.info.id + "</strong>";
		this.cellInfo = cellInfo;
		return cellInfo;
	}

	static clear() {
		let arr = document.getElementsByClassName("cell-info");
		for (var i = 0; i < arr.length; i++) {
			let cellInfo = arr[i];
			cellInfo.remove();
		}
	}
	getElement() {
		return this.cellInfo;
	}
}
